<template>
    <div class="container-fluid" v-loading="loading">

        <div class="row">
            <div class="col-md-12">
                <div class="card">
                    <div class="card-header"><h4>消息内容设置</h4></div>
                    <div class="card-toolbar clearfix">
                        <div class="toolbar-btn-action" style="padding-bottom:25px;">
                            <a class="btn btn-primary m-r-5 btn-sm" :href="'/admin/wechat/'+item.app_id+'/edit'" target="_blank" v-for="item in list"><i class="mdi mdi-plus"></i> {{ item.app_id }}</a>
                        </div>
                    </div>
                </div>
            </div>
        </div>



    </div>
</template>

<script>
    export default {
        name: "WechatComponent",
        data(){
            return {
                loading:false,
                list:[]
            }
        },
        methods:{
            search: function () {
                let self = this;
                let uri = 'wechat/post-list';
                self.loading = true;
                let postData = {};

                axios.post(uri,postData).then(function (result) {
                    self.list = result;
                    self.loading = false;
                },function (error) {
                    self.loading = false;
                });
            },
        },
        mounted() {
            this.search();
        }
    }
</script>

<style scoped>

</style>
